package com.fs.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.Date;

/**
 * @author python_boy
 * @fileName WhOutbound
 * @date 2024/10/11 19:34
 * @description 出库单模型
 **/
@NoArgsConstructor
@AllArgsConstructor
@Data
@TableName("wh_outbound")
public class WhOutbound {  //出库单类
    @TableId(type = IdType.AUTO)
    private Integer outboundEntryId;  //出库单编号
    @JsonFormat(pattern = "yyyy-MM-dd")
    private Date outboundDate;  //出库日期
    private String outboundType;  //出库类型
    private Integer customerId;  //客户编号
    private Integer warehouseId;  //仓库编号
    private String outbounder;  //出库人
    private Integer total; //出库总数量
    private Integer totalAmount;  //出库总金额
    private String outboundNotes;  //出库备注
    private Integer approvalStatus;  //审批状态
    private Integer approverId;  //审批人编号
    @JsonFormat(pattern = "yyyy-MM-dd")
    private Date approvalDate;  //审批日期
    @TableField(exist = false)
    private String warehouseName;

    public WhOutbound(String outStoActor, Date outboundDate, String outboundType, Integer warehouseId, Integer total, String outboundNotes, Integer approvalStatus, Integer approverId, Date approvalDate) {
        this.outbounder=outStoActor;
        this.outboundDate=outboundDate;
        this.outboundType = outboundType;
        this.warehouseId = warehouseId;
        this.total = total;
        this.outboundNotes = outboundNotes;
        this.approvalStatus = approvalStatus;
        this.approverId = approverId;
        this.approvalDate = approvalDate;
    }
}
